package com.galaxy.commom.base.enums;

import com.galaxy.commom.base.constant.SystemConstants;

/**
 * @author caijinbang
 * @date 2018/9/7 20:28
 */
public enum CacheNamespaceEnum {

  /**
   * 数据缓存
   */
  DATA(SystemConstants.CACHE_NAMESPACE_PREFIX + "data:", "数据缓存"),
  LOCK(SystemConstants.CACHE_NAMESPACE_PREFIX + "lock:", "分布式锁"),
  TOKEN(SystemConstants.CACHE_NAMESPACE_PREFIX + "token:", "票据"),
  CAPTCHA(SystemConstants.CACHE_NAMESPACE_PREFIX + "captcha:", "验证码"),
  SHIRO(SystemConstants.CACHE_NAMESPACE_PREFIX + "shiro:", "shiro"),
  IP(SystemConstants.CACHE_NAMESPACE_PREFIX + "ip:", "ip归属地");

  /**
   * 值
   */
  private String value;
  /**
   * 描述
   */
  private String message;

  CacheNamespaceEnum(String value, String message) {
    this.value = value;
    this.message = message;
  }

  public String value() {
    return this.value;
  }

  public String getMessage() {
    return this.message;
  }
}
